Skip to content

conformance: Add conformance tests for implementation and platform checks. - #2375

Closed
Josverl wants to merge 10 commits into
python:mainfrom
Josverl:conf/sys_version_platform
Closed

Josverl wants to merge 10 commits into
python:mainfrom
Josverl:conf/sys_version_platform

Conversation

@Josverl

@Josverl Josverl commented Oct 23, 2026 •

Copy link
Copy Markdown

Add conformance tests and results for implementation and platform checks as defined in #2173

  • Add relevant tests
  • Extend conformance tests documentation
  • Updated existing TOML files to include additional error messages for unresolved references and type assertion failures.

This is based on #2173 , once that PR gets squashed / merged this commit will be rebased

Trade-offs

The some of the added test are hardcoded for:

  • Python version: >= 3.12
  • Platform: Linux

If/when the version or tested platforms for the conformance tests change, these tests will need to be reviewed and likely adjusted.

In directives_platform_checks.py:

  • Equality and basic prefix checks: portable. They use "bogus_platform" or the empty prefix.
  • Tuple/set/list membership tests: basic checks are portable, but the guarded positive membership cases require a Linux target.
  • Versioned-platform prefix test: the actual "freebsd" versus "linux" prefix checks require a freebsd13 target.

On another target, those guarded tests take an outer else branch containing deliberately expected errors. The file can therefore pass without exercising the Linux-specific or FreeBSD-specific inner checks.

Josverl and others added 10 commits August 15, 2026 22:15
…atform checks.

Signed-off-by: Jos Verlinde <jos_verlinde@hotmail.com>
Formatting improvements.

Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
…sion comparisons.

Signed-off-by: Jos Verlinde <jos_verlinde@hotmail.com>
Signed-off-by: Jos Verlinde <jos_verlinde@hotmail.com>
Also :
-  wrapped lines to ~85 characters
- tables to 110 characters
- Improved .rst formatting and markup

The Intent is for these commits allow tracability of review comments,
but to be squashed to a single commit during merge.

Signed-off-by: Jos Verlinde <jos_verlinde@hotmail.com>
Minor changes to wording and formatting.

Signed-off-by: Jos Verlinde <jos_verlinde@hotmail.com>
Signed-off-by: Jos Verlinde <jos_verlinde@hotmail.com>
Signed-off-by: Jos Verlinde <jos_verlinde@hotmail.com>
…checks.

- Introduced new TOML files for various conformance results related to directives implementation version, platform checks, and version/platform boolean checks.
- Marked conformance as "Unsupported" or "Partial" based on the ability to prune branches for specific checks.
- Documented unexpected errors and output related to type assignment issues, particularly with `Literal` types and incompatible types in assignments.
- Updated existing TOML files to include additional error messages for unresolved references and type assertion failures.

Signed-off-by: Jos Verlinde <jos_verlinde@hotmail.com>
@Josverl Josverl changed the title Conf/sys version platform conformance: Add conformance tests for implementation and platform checks. Oct 23, 2026
@jorenham jorenham added the topic: conformance tests Issues with the conformance test suite label Oct 23, 2026
@Josverl

Josverl commented Oct 30, 2026

Copy link
Copy Markdown
Author

the tests have been adsorbed into #2173

@Josverl Josverl closed this Oct 30, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

topic: conformance tests Issues with the conformance test suite

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants